package com.rc.pojo.po.table;

import com.mybatisflex.core.query.QueryColumn;
import com.mybatisflex.core.table.TableDef;

// Auto generate by mybatis-flex, do not modify it.
public class AdoptionTableDef extends TableDef {

    /**
     * 实体类。

 @author 27806
 @since 2024-06-16
     */
    public static final AdoptionTableDef ADOPTION = new AdoptionTableDef();

    public final QueryColumn ID = new QueryColumn(this, "id");

    public final QueryColumn IMGS = new QueryColumn(this, "imgs");

    /**
     * 价格
     */
    public final QueryColumn PRICE = new QueryColumn(this, "price");

    /**
     * 评分
     */
    public final QueryColumn SCORE = new QueryColumn(this, "score");

    /**
     * 活动名称
     */
    public final QueryColumn TITLE = new QueryColumn(this, "title");

    public final QueryColumn FARM_ID = new QueryColumn(this, "farm_id");

    public final QueryColumn PLANT_ID = new QueryColumn(this, "plant_id");

    public final QueryColumn CREATE_TIME = new QueryColumn(this, "create_time");

    public final QueryColumn CREATE_USER = new QueryColumn(this, "create_user");

    public final QueryColumn UPDATE_TIME = new QueryColumn(this, "update_time");

    public final QueryColumn UPDATE_USER = new QueryColumn(this, "update_user");

    /**
     * 认养简介
     */
    public final QueryColumn DESCRIPTION = new QueryColumn(this, "description");

    /**
     * 发货周期
     */
    public final QueryColumn DELIVERY_CYCLE = new QueryColumn(this, "delivery_cycle");

    /**
     * 发货方式
     */
    public final QueryColumn DELIVERY_METHOD = new QueryColumn(this, "delivery_method");

    /**
     * 预计收益
     */
    public final QueryColumn EXPECTED_REVENUE = new QueryColumn(this, "expected_revenue");

    /**
     * 所有字段。
     */
    public final QueryColumn ALL_COLUMNS = new QueryColumn(this, "*");

    /**
     * 默认字段，不包含逻辑删除或者 large 等字段。
     */
    public final QueryColumn[] DEFAULT_COLUMNS = new QueryColumn[]{ID, IMGS, PRICE, SCORE, TITLE, FARM_ID, PLANT_ID, CREATE_TIME, CREATE_USER, UPDATE_TIME, UPDATE_USER, DESCRIPTION, DELIVERY_CYCLE, DELIVERY_METHOD, EXPECTED_REVENUE};

    public AdoptionTableDef() {
        super("rc", "adoption");
    }

    private AdoptionTableDef(String schema, String name, String alisa) {
        super(schema, name, alisa);
    }

    public AdoptionTableDef as(String alias) {
        String key = getNameWithSchema() + "." + alias;
        return getCache(key, k -> new AdoptionTableDef("rc", "adoption", alias));
    }

}
